package com.hhh.springai_test.model.enums;

public enum IsPasswordEnum {
    NO(0, "否"),
    YES(1, "是");

    private Integer code;
    private String msg;

    public static String getMsg(Integer code) {
        for (IsPasswordEnum value : IsPasswordEnum.values()) {
            if (value.getCode().equals(code)) {
                return value.getMsg();
            }
        }
        return null;
    }

    IsPasswordEnum(Integer code, String msg) {
        this.code = code;
        this.msg = msg;
    }

    public Integer getCode() {
        return code;
    }

    public void setCode(Integer code) {
        this.code = code;
    }

    public String getMsg() {
        return msg;
    }

    public void setMsg(String msg){}
}
